<?php
class User_Form_Login extends Custom_Form
{
    public function init()
    {
        $translate = Zend_Registry::get('translate');
        $this->setName("login");
        $this->setMethod('post');

        $this->addElement('text', 'username', array(
            'label' => $translate->_('Username'),
            'required' => true,
        ));

        $this->addElement('password', 'password', array(
            'required' => true,
            'label' => $translate->_('Password'),
        ));

        $this->addElement('checkbox', 'rememberMe', array(
            'required' => false,
            'class' => 'checkbox',
            'label' => $translate->_('Remember me')));
        
      
        $this->addElement('submit', 'Login', 
                            array('ignore' => true, 
                                 'required' => false,
                                 'label' => $translate->_('Login'),
                                  ));

        $element = $this->getElement('Login');
        $element->removeDecorator('label');
        
        $this->rememberMe->getDecorator('Label')->setOption('placement', 'append');
        $this->password->removeDecorator('errors');
        $this->username->removeDecorator('errors');
    }
    
}
?>
